/*
 * Copyright (c) 2024 Shenzhen Kaihong Digital Industry Development Co., Ltd.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#include <gtest/gtest.h>

#include "sle_error_code.h"
#include "sle_ssap_client_stub.h"
#include "i_sle_ssap_server_callback.h"
#include "mock_ipcobject_stub.h"
#include "sle_ssap_client_callback_stub.h"
#include "sle_ssap_client_proxy.h"
#include "g_val.h"

class SleSsapClientStubTest : public testing::Test {
public:
    static void SetUpTestCase();
    static void TearDownTestCase();
    void SetUp() override;
    void TearDown() override;

};
void SleSsapClientStubTest::SetUp()
{
}

void SleSsapClientStubTest::TearDown()
{
}

void SleSsapClientStubTest::SetUpTestCase()
{
}

void SleSsapClientStubTest::TearDownTestCase()
{
}

namespace OHOS {
namespace NearLink {
namespace SleStandard {

class SleSsapClientStubMock : public SleSsapClientStub {
    public:
        SleErrorCode RegisterSsapClient(const Uuid &uuid, uint8_t &clientId, const sptr<ISleSsapClientCallback> &callback)
        {
            clientId = 1;
            return ERR_NONE;
        }
        SleErrorCode UnregisterSsapClient(uint8_t clientId, const sptr<ISleSsapClientCallback> &callback)
        {
            return ERR_NONE;
        }
        SleErrorCode FindSsapStructure(uint8_t clientId, uint16_t connectId, const SsapClientFindStructure &param)
        {
            return ERR_NONE;
        }
        SleErrorCode ReadRequestByUuid(uint8_t clientId, uint16_t connectId, const SsapClientReadReqByUUID &param)
        {
            return ERR_NONE;
        }
        SleErrorCode ReadRequest(uint8_t clientId, uint16_t connectId, uint16_t handle, uint8_t type)
        {
            return ERR_NONE;
        }
        SleErrorCode WriteRequest(uint8_t clientId, uint16_t connectId, const SsapClientHandleValue &value)
        {
            return ERR_NONE;
        }
        SleErrorCode WriteCommand(uint8_t clientId, uint16_t connectId, const SsapClientHandleValue &value)
        {
            return ERR_NONE;
        }
        SleErrorCode ExchangeInfo(uint8_t clientId, uint16_t connectId, uint32_t mtu, uint16_t version)
        {
            return ERR_NONE;
        }
};

class SleSsapClientCallbackStubMock : public SleSsapClientCallbackStub {
    public:
        void OnFindService(uint8_t clientId, uint16_t connectId, const SsapClientFindServiceRes &result, uint32_t errCode)
        {
            return;
        }
        void OnFindProperty(uint8_t clientId, uint16_t connectId, const SsapClientFindPropertyRes &result, uint32_t errCode)
        {
            return;
        }
        void OnFindComplete(uint8_t clientId, uint16_t connectId, uint8_t type, const Uuid &uuid, uint32_t errCode)
        {
            return;
        }
        void OnWriteResult(uint8_t clientId, uint16_t connectId, uint16_t handle, uint8_t type, uint32_t errCode)
        {
            return;
        }
        void OnReadResult(uint8_t clientId, uint16_t connectId, const SsapClientHandleValue &value, uint32_t errCode)
        {
            return;
        }
        void OnReadByUuidComplete(uint8_t clientId, uint16_t connectId, uint8_t type, const Uuid &uuid, uint32_t errCode)
        {
            return;
        }
        void OnExchangeInfo(uint8_t clientId, uint16_t connectId, uint32_t mtu, uint16_t version, uint32_t errCode)
        {
            return;
        }
        void OnNotification(uint8_t clientId, uint16_t connectId, const SsapClientHandleValue &value, uint32_t errCode)
        {
            return;
        }
        void OnIndication(uint8_t clientId, uint16_t connectId, const SsapClientHandleValue &value, uint32_t errCode)
        {
            return;
        }
};


/************************************************kaihong/communication/nearlink/sle/sle_standard/frameworks/ipc/source stub******************************************************** */
HWTEST_F(SleSsapClientStubTest, OnFindServiceInner_201, testing::ext::TestSize.Level0)
{
    SleSsapClientCallbackStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientCallbackStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    SsapClientFindServiceRes sfsr;
    data.WriteParcelable(&sfsr);
    data.WriteUint32(1);
    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_CALLBACK_FIND_SERVICE, data, reply, option), NO_ERROR);
}

HWTEST_F(SleSsapClientStubTest, OnFindPropertyInner_201, testing::ext::TestSize.Level0)
{
    SleSsapClientCallbackStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientCallbackStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    SsapClientFindPropertyRes sfsr;
    data.WriteParcelable(&sfsr);
    data.WriteUint32(1);
    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_CALLBACK_FIND_PROPERTY, data, reply, option), NO_ERROR);
}


HWTEST_F(SleSsapClientStubTest, OnFindCompleteInner_201, testing::ext::TestSize.Level0)
{
    SleSsapClientCallbackStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientCallbackStub::GetDescriptor());

    std::shared_ptr<Uuid> uuid = std::make_shared<Uuid>();
    uuid->ConvertToSleUuid();

    data.WriteUint8(1);
    data.WriteUint16(1);
    data.WriteUint8(1);
    data.WriteParcelable(uuid.get());
    data.WriteUint32(1);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_CALLBACK_FIND_COMPLETE, data, reply, option), NO_ERROR);
}

HWTEST_F(SleSsapClientStubTest, OnWriteResultInner_201, testing::ext::TestSize.Level0)
{
    SleSsapClientCallbackStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientCallbackStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    data.WriteUint16(1);
    data.WriteUint8(1);
    data.WriteUint32(1);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_CALLBACK_WRITE_REASULT, data, reply, option), NO_ERROR);
}


HWTEST_F(SleSsapClientStubTest, OnReadResultInner_201, testing::ext::TestSize.Level0)
{
    SleSsapClientCallbackStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientCallbackStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    SsapClientHandleValue sfsr;
    data.WriteParcelable(&sfsr);
    data.WriteUint32(1);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_CALLBACK_READ_RESULT, data, reply, option), NO_ERROR);
}


HWTEST_F(SleSsapClientStubTest, OnReadByUuidCompleteInner_201, testing::ext::TestSize.Level0)
{
    SleSsapClientCallbackStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientCallbackStub::GetDescriptor());

    std::shared_ptr<Uuid> uuid = std::make_shared<Uuid>();
    uuid->ConvertToSleUuid();

    data.WriteUint8(1);
    data.WriteUint16(1);
    data.WriteUint8(1);
    data.WriteParcelable(uuid.get());
    data.WriteUint32(1);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_CALLBACK_READ_BY_UUID_COMPLETE, data, reply, option), NO_ERROR);
}


HWTEST_F(SleSsapClientStubTest, OnExchangeInfoInner_201, testing::ext::TestSize.Level0)
{
    SleSsapClientCallbackStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientCallbackStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    data.WriteUint32(1);
    data.WriteUint16(1);
    data.WriteUint32(1);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_CALLBACK_EXCHANGE_INFO, data, reply, option), NO_ERROR);
}


HWTEST_F(SleSsapClientStubTest, OnNotificationInner_201, testing::ext::TestSize.Level0)
{
    SleSsapClientCallbackStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientCallbackStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    SsapClientHandleValue sfsr;
    data.WriteParcelable(&sfsr);
    data.WriteUint32(1);
    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_CALLBACK_NOTIFICATION, data, reply, option), NO_ERROR);
}


HWTEST_F(SleSsapClientStubTest, OnIndicationInner_201, testing::ext::TestSize.Level0)
{
    SleSsapClientCallbackStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientCallbackStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    SsapClientHandleValue sfsr;
    data.WriteParcelable(&sfsr);
    data.WriteUint32(1);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_CALLBACK_INDICATION, data, reply, option), NO_ERROR);
}
/************************************************kaihong/communication/nearlink/sle/sle_standard/frameworks/ipc/source stub******************************************************** */


/************************************************kaihong/communication/nearlink/sle/sle_standard/frameworks/ipc/source proxy******************************************************** */

HWTEST_F(SleSsapClientStubTest, UnregisterSsapClient_301, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 1;
    sptr<SleSsapClientCallbackStubMock> callback = new SleSsapClientCallbackStubMock();

    uint8_t clientId = 1;
    SleErrorCode result = proxy->UnregisterSsapClient( clientId, callback);
    EXPECT_EQ(result, (SleErrorCode)7);

}

HWTEST_F(SleSsapClientStubTest, UnregisterSsapClient_302, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 0;
    sptr<SleSsapClientCallbackStubMock> callback = new SleSsapClientCallbackStubMock();

    uint8_t clientId = 1;
    SleErrorCode result = proxy->UnregisterSsapClient( clientId, callback);
    EXPECT_EQ(result, (SleErrorCode)0);
}


HWTEST_F(SleSsapClientStubTest, FindSsapStructure_301, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 1;


    uint8_t clientId = 1;
    uint16_t connectId = 1;
    SsapClientFindStructure param;
    SleErrorCode result = proxy->FindSsapStructure( clientId, connectId, param);
    EXPECT_EQ(result, (SleErrorCode)7);

}

HWTEST_F(SleSsapClientStubTest, FindSsapStructure_302, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 0;

    uint8_t clientId = 1;
    uint16_t connectId = 1;
    SsapClientFindStructure param;
    SleErrorCode result = proxy->FindSsapStructure( clientId, connectId, param);
    EXPECT_EQ(result, (SleErrorCode)0);

}



HWTEST_F(SleSsapClientStubTest, ReadRequestByUuid_301, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 1;


    uint8_t clientId = 1;
    uint16_t connectId = 1;
    SsapClientReadReqByUUID param;
    SleErrorCode result = proxy->ReadRequestByUuid( clientId, connectId, param);
    EXPECT_EQ(result, (SleErrorCode)7);

}

HWTEST_F(SleSsapClientStubTest, ReadRequestByUuid_302, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 0;

    uint8_t clientId = 1;
    uint16_t connectId = 1;
    SsapClientReadReqByUUID param;
    SleErrorCode result = proxy->ReadRequestByUuid( clientId, connectId, param);
    EXPECT_EQ(result, (SleErrorCode)0);

}



HWTEST_F(SleSsapClientStubTest, ReadRequest_301, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 1;


    uint8_t clientId = 1;
    uint16_t connectId = 1;
    uint16_t handle = 1;
    uint8_t type = 1;
    SleErrorCode result = proxy->ReadRequest(  clientId,  connectId,  handle,  type);
    EXPECT_EQ(result, (SleErrorCode)7);

}

HWTEST_F(SleSsapClientStubTest, ReadRequest_302, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 0;

    uint8_t clientId = 1;
    uint16_t connectId = 1;
    uint16_t handle = 1;
    uint8_t type = 1;
    SleErrorCode result = proxy->ReadRequest(  clientId,  connectId,  handle,  type);
    EXPECT_EQ(result, (SleErrorCode)0);

}


HWTEST_F(SleSsapClientStubTest, WriteRequest_301, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 1;


    uint8_t clientId = 1;
    uint16_t connectId = 1;
    SsapClientHandleValue param;
    SleErrorCode result = proxy->WriteRequest( clientId, connectId, param);
    EXPECT_EQ(result, (SleErrorCode)7);
}

HWTEST_F(SleSsapClientStubTest, WriteRequest_302, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 0;

    uint8_t clientId = 1;
    uint16_t connectId = 1;
    SsapClientHandleValue param;
    SleErrorCode result = proxy->WriteRequest( clientId, connectId, param);
    EXPECT_EQ(result, (SleErrorCode)0);
}



HWTEST_F(SleSsapClientStubTest, WriteCommand_301, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 1;


    uint8_t clientId = 1;
    uint16_t connectId = 1;
    SsapClientHandleValue param;
    SleErrorCode result = proxy->WriteCommand( clientId, connectId, param);
    EXPECT_EQ(result, (SleErrorCode)7);
}

HWTEST_F(SleSsapClientStubTest, WriteCommand_302, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 0;

    uint8_t clientId = 1;
    uint16_t connectId = 1;
    SsapClientHandleValue param;
    SleErrorCode result = proxy->WriteCommand( clientId, connectId, param);
    EXPECT_EQ(result, (SleErrorCode)0);
}


HWTEST_F(SleSsapClientStubTest, ExchangeInfo_301, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 1;


    uint8_t clientId = 1;
    uint16_t connectId = 1;
    uint32_t mtu = 1;
    uint16_t version = 1;
    SleErrorCode result = proxy->ExchangeInfo(  clientId,  connectId,  mtu,  version);
    EXPECT_EQ(result, (SleErrorCode)7);
}

HWTEST_F(SleSsapClientStubTest, ExchangeInfo_302, testing::ext::TestSize.Level0)
{
    sptr<IRemoteObject> mockStub = new MockIPCObjectStub(u"test");
    std::shared_ptr<SleSsapClientProxy> proxy = std::make_shared<SleSsapClientProxy>(mockStub);
    g_ControlVal = 0;

    uint8_t clientId = 1;
    uint16_t connectId = 1;
    uint32_t mtu = 1;
    uint16_t version = 1;
    SleErrorCode result = proxy->ExchangeInfo(  clientId,  connectId,  mtu,  version);
    EXPECT_EQ(result, (SleErrorCode)0);
}



/************************************************kaihong/communication/nearlink/sle/sle_standard/frameworks/ipc/source proxy******************************************************** */



/************************************************communication/nearlink/sle/sle_standard/services/ipc******************************************************** */

HWTEST_F(SleSsapClientStubTest, RegisterSsapClientInner_001, testing::ext::TestSize.Level0)
{
    SleSsapClientStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientStub::GetDescriptor());

    std::shared_ptr<Uuid> uuid = std::make_shared<Uuid>();
    uuid->ConvertToSleUuid();
    sptr<IRemoteObject> remoteObject = new SleSsapClientCallbackStubMock();
    data.WriteParcelable(uuid.get());
    data.WriteRemoteObject(remoteObject);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_REGISTER_CLIENT, data, reply, option), NO_ERROR);
}
/********************************************************************************************************************/

HWTEST_F(SleSsapClientStubTest, UnregisterSsapClientInner_001, testing::ext::TestSize.Level0)
{
    SleSsapClientStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientStub::GetDescriptor());

    data.WriteUint8(1);
    sptr<IRemoteObject> remoteObject = new SleSsapClientCallbackStubMock();
    data.WriteRemoteObject(remoteObject);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_UNREGISTER_CLIENT, data, reply, option), NO_ERROR);
}
/********************************************************************************************************************/

HWTEST_F(SleSsapClientStubTest, FindSsapStructureInner_001, testing::ext::TestSize.Level0)
{
    SleSsapClientStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    SsapClientFindStructure param;
    data.WriteParcelable(&param);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_FIND_STRUCTURE, data, reply, option), NO_ERROR);
}
/********************************************************************************************************************/

HWTEST_F(SleSsapClientStubTest, ReadRequestByUuidInner_001, testing::ext::TestSize.Level0)
{
    SleSsapClientStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    SsapClientReadReqByUUID param;
    data.WriteParcelable(&param);

    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_READ_REQUEST_BY_UUID, data, reply, option), NO_ERROR);
}
/********************************************************************************************************************/

HWTEST_F(SleSsapClientStubTest, ReadRequestInner_001, testing::ext::TestSize.Level0)
{
    SleSsapClientStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    data.WriteUint16(1);
    data.WriteUint8(1);
    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_READ_REQUEST, data, reply, option), NO_ERROR);
}
/********************************************************************************************************************/

HWTEST_F(SleSsapClientStubTest, WriteRequestInner_001, testing::ext::TestSize.Level0)
{
    SleSsapClientStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    SsapClientHandleValue param;
    data.WriteParcelable(&param);
    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_WRITE_REQUEST, data, reply, option), NO_ERROR);
}
/********************************************************************************************************************/

HWTEST_F(SleSsapClientStubTest, WriteCommandInner_001, testing::ext::TestSize.Level0)
{
    SleSsapClientStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    SsapClientHandleValue param;
    data.WriteParcelable(&param);
    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_WRITE_COMMAND, data, reply, option), NO_ERROR);
}
/********************************************************************************************************************/

HWTEST_F(SleSsapClientStubTest, ExchangeInfoInner_001, testing::ext::TestSize.Level0)
{
    SleSsapClientStubMock ssapClient;
    MessageParcel data;
    MessageParcel reply;
    MessageOption option;
    data.WriteInterfaceToken(SleSsapClientStub::GetDescriptor());

    data.WriteUint8(1);
    data.WriteUint16(1);
    data.WriteUint32(1);
    data.WriteUint16(1);
    EXPECT_EQ(ssapClient.OnRemoteRequest(SLE_SSAP_CLIENT_EXCHANGE_REQUEST, data, reply, option), NO_ERROR);
}
/********************************************************************************************************************/

}}}